package il.ac.braude.sona.database;

import java.io.Serializable;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.HashMap;

public class ChangeRequest implements Serializable {
	public static final String[] fields = { "rid","title","comment" };
	private HashMap<String,String> values = new HashMap<String,String>();
	public ChangeRequest(ResultSet resultSet) throws SQLException {
		for (String f : fields) 
			values.put(f, resultSet.getString(f));
	}
	public String toString() {
		return values.toString();
	}
	public String getValue(String key) {
		return values.get(key);
	}
}
